function Person(){}
Person.prototype = {
    name:'tom'
}
//判断属性是否属于原型
function hasPrototypeProperty(object,name)··{
    //hasOwnProperty()属性存在于实例中返回true
    return !object.hasOwnProperty(name) && (name in object)
}
var person = new Person();
console.log(hasPrototypeProperty(person,'name'))
person.name = 'moyu'
console.log(hasPrototypeProperty(person,'name'))
